package day5;

import java.util.Scanner;

public class Demo2 {
    public static void main(String[] args) {
        boolean a = true;
        boolean b = true;
        boolean c = a && b;
        System.out.println("c:"+c);

        //判断一个数字能否同时被3,5整除
        System.out.println("请输入一个数字");
        Scanner sc  = new Scanner(System.in);
        int num = sc.nextInt();
        if((num%3==0)&&(num%5==0)){
            System.out.println("可以同时被3,5整除");
        }else {
            System.out.println("不能被同时整除");
        }
        //判断一个数是否是3的整数倍或5的整数倍
        System.out.println("请输入一个数字");
        Scanner sc2  = new Scanner(System.in);
        int num2 = sc2.nextInt();
        if((num2%3==0)||(num2%5==0)){
            System.out.println("是");
        }else {
            System.out.println("不是");
        }
    }


}
